<%@ page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="../common/include.inc.jsp"%>
<div class="pageContent">
	<form method="post" action="student/update" class="pageForm required-validate" onsubmit="return validateCallback(this, dialogAjaxDone);">
		<input type="hidden" name="id" value="${student.id}"/>
		<input type="hidden" name="studentInfo.score" value="${student.studentInfo.score}"/>
		<input type="hidden" name="createDateStr" value="<fmt:formatDate value='${student.createDate}' pattern='yyyy-MM-dd HH:mm:ss'/>"/>
		<div class="pageFormContent" layoutH="56">
			<p>
				<label>姓名：</label>
				<input name="name" type="text" size="30" value="${student.name}" class="required" ></input>
			</p>
			<p>
				<label>性别：</label>
				<select name="sex" class="required">
					<option value="">未选择</option>
					<option value="男" <c:if test="${student.sex=='男' }">selected</c:if> >男<option>
					<option value="女" <c:if test="${student.sex=='女' }">selected</c:if> >女</option>
				</select>
			</p>
			<p>
				<label>班级：</label>
				<select name="studentClass.classId" clss="required">
					<option value="">未选择</option>
					<c:forEach var="stuClass" items="${classList }">
					<option value="${stuClass.classId }" <c:if test="${student.studentClass.classId==stuClass.classId }">selected</c:if> >${stuClass.className }</option>
					</c:forEach>
				</select>
			</p>
			<p>
				<label>年龄：</label>
				<input type="text" name="age" value="${student.age }"></input>
			</p>
			<p>
				<label>地址：</label>
				<input type="text" name="address" value="${student.address }"></input>
			</p>
			<p>
				<label>父母：</label>
				<input type="text" name="studentInfo.parentName" value="${student.studentInfo.parentName }" class="required"></input>
			</p>
			<p>
				<label>电话：</label>
				<input type="text" name="studentInfo.phone" value="${student.studentInfo.phone }"></input>
			</p>
			<p>
				<label>邮箱：</label>
				<input type="text" name="studentInfo.email" value="${student.studentInfo.email }"></input>
			</p>
		</div>
		<div class="formBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">保存</button></div></div></li>
				<li>
					<div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div>
				</li>
			</ul>
		</div>
	</form>
</div>
